using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace Workflows.Components
{
    public partial class GlobalVariableEditorForm : Form
    {
        private static GlobalVariableEditorForm _Form=new GlobalVariableEditorForm();

        public GlobalVariableEditorForm()
        {
            InitializeComponent();
        }

        public static void Edit(ref Dictionary<string,object> globalVars)
        {
            _Form.GlobalVars = globalVars;
            if (_Form.ShowDialog() == System.Windows.Forms.DialogResult.OK)
                globalVars = _Form.GlobalVars;
        }

        public Dictionary<string, object> _GlobalVars;

        public Dictionary<string, object> GlobalVars
        {
            get { return _GlobalVars; }
            set { _GlobalVars = value; }
        }

    }
}